dbe3a30c-a4ef-4975-b224-628947f98729 1.0 2013 4 player help You can't do that. north|east|south|west|northeast|northwest|southeast|southwest|out|up|down|n|e|s|w|ne|nw|se|sw|o|u|d)$]]> Room labelled number 1 Red The room has red walls. A suprisingly clean shovel. Room labelled number 2 Blue The room has blue walls. list = FormatObjectList("", Large bag, ",", "", true) if (list = "") { if (Large bag.isopen) { msg ("A large bag made of leather. It is currently open and contains nothing.") } else { msg ("A large bag made of leather. It is currently closed.") } } else { if (Large bag.isopen) { msg ("A large bag made of leather. It is currently open and contains " + list + ".") } else { msg ("A large bag made of leather. It is currently closed.") } } list = FormatObjectList("", Small bag, ",", "", true) if (list = "") { if (Small bag.isopen) { msg ("A small bag made of leather. It is currently open and contains nothing.") } else { msg ("A small bag made of leather. It is currently closed.") } } else { if (Small bag.isopen) { msg ("A small bag made of leather. It is currently open and contains " + list + ".") } else { msg ("A small bag made of leather. It is currently closed.") } } Room labelled number 3 Green The room has green walls. The room is too dark to see anything that is not lit. weak weak weak A perfectly round stone. Switch weak A mildly glowing switch. You can turn it on or off. set (Lamp1, "lightsource", true) set (Lamp1, "lightsource", false) Lamp strong false Room labelled number 4 Yellow The room has yellow walls. A pretty dirty shirt. false Room labelled number 5 Purple The room has purple walls. Room labelled number 6 Orange The room has orange walls. The room is too dark to see anything that is not lit. weak A boring old table. A regular lamp. You can take it with you and turn it on as well as off. false strong set (Portable lamp, "lightsource", true) set (Portable lamp, "lightsource", false) Switch A mildly glowing switch. You can turn it on or off. weak set (Lamp2, "lightsource", true) set (Lamp2, "lightsource", false) Lamp strong 0) { msg (desc) desc = "" } do (exit.to, descriptionfield) if (game.autodescription_description_newline) { msg ("") } } else { desc = AddDescriptionLine(desc, GetRoomDescriptionOfLookDir(exit)) if (game.autodescription_description_newline) { msg (desc) desc = "" } } } } if (LengthOf(desc) > 0) { msg (desc) } } else { if (HasScript(exit.to, descriptionfield)) { do (exit.to, descriptionfield) } else { fulldesc = GetRoomDescriptionOfLookDir(exit) if (LengthOf(fulldesc) > 0) { msg (fulldesc) } } } ]]> 0) { fulldesc = exit.to.darkroomdescription } } } else { if (HasString(exit.to, "description")) { if (LengthOf(exit.to.description) > 0) { fulldesc = exit.to.description } } } if (game.appendobjectdescription) { foreach (val, ScopeVisibleNotHeld()) { if (HasString(val, "inroomdescription")) { if (LengthOf(val.inroomdescription) > 0 and val <> game.pov) { fulldesc = fulldesc + " " + val.inroomdescription } } } } return (Trim(fulldesc)) ]]> null) { if (DictionaryContains(game.pov.commandmetadata, value)) { result = GetObject(StringDictionaryItem(game.pov.commandmetadata, value)) if (result <> null) { if (ListContains(ScopeVisible(), result)) { found = true return (result) } } } } if (not found) { value = LCase(value) if (game.pov.currentcommandpattern.name = "lookat") { result = ResolveNameInternalEdited(variable, value, objtype) } else { result = ResolveNameInternal(variable, value, objtype) } if (result <> null) { return (result) } else { // TO DO: Check this behaviour. We only want to try ignoring prefixes if we have definitely got an unresolved name. foreach (prefix, game.parserignoreprefixes) { if (StartsWith(value, prefix + " ")) { result = ResolveNameInternal(variable, Mid(value, LengthOf(prefix) + 1), objtype) } } if (result = null and LengthOf(variable) = 0 and not GetBoolean(game.pov, "currentcommandmultiobjectpending")) { UnresolvedCommand (value, game.pov.currentcommandpendingvariable) } return (result) } } ]]> null) { foreach (altname, obj.alt) { CompareNames (LCase(altname), value, obj, fullmatches, partialmatches) } } } if (game.lastobjects <> null) { foreach (obj, game.lastobjects) { CompareNames (LCase(obj.article), value, obj, fullmatches, partialmatches) CompareNames (LCase(obj.gender), value, obj, fullmatches, partialmatches) } } if (ListCount(fullmatches) = 1) { return (ListItem(fullmatches, 0)) } else if (ListCount(fullmatches) = 0 and ListCount(partialmatches) = 1) { return (ListItem(partialmatches, 0)) } else if (ListCount(fullmatches) + ListCount(partialmatches) = 0) { return (null) } else { menu = NewStringDictionary() GenerateMenuChoices (menu, fullmatches) GenerateMenuChoices (menu, partialmatches) if (LengthOf(variable) > 0) { // single object command, so after showing the menu, add the object to game.pov.currentcommandresolvedelements game.pov.currentcommandpendingvariable = variable ShowMenu (DynamicTemplate("DisambiguateMenu", value), menu, true) { varname = game.pov.currentcommandpendingvariable game.pov.currentcommandpendingvariable = null if (result <> null) { AddToResolvedNames (varname, GetObject(result)) } } } else { // multi-object command, so after showing the menu, add the object to the list game.pov.currentcommandmultiobjectpending = true ShowMenu (DynamicTemplate("DisambiguateMenu", value), menu, true) { if (result <> null) { list add (game.pov.currentcommandpendingobjectlist, GetObject(result)) ResolveNextNameListItem } } } return (null) } ]]> 0) { roomCheckDarkness = false } } else { roomCheckDarkness = false } exit.to.darklevel = roomCheckDarkness return (roomCheckDarkness) ]]> list = NewObjectList() foreach (object, AllObjects()) { if (Contains (exit.to,object) and object.visible = true) { if (object.parent.container = true and object.parent.isopen = true ) { if (HasAttribute(object.parent, "transparent ")) { if (object.parent.transparent = true) { list add (list, object) } } else { list add (list, object) } } else if (object.parent.container = false) { list add (list, object) } } } result = list lightobjects = NewObjectList() foreach (obj, result) { if (GetBoolean(obj, "lightsource") and GetString(obj, "lightstrength") = lightstrength) { list add (lightobjects, obj) } } exitslist = NewObjectList() foreach (exit1, AllExits()) { if (exit1.parent = exit.to) { list add (exitslist, exit1) } } exits = exitslist foreach (obj, exits) { if (GetBoolean(obj, "lightsource") and GetString(obj, "lightstrength") = lightstrength) { list add (lightobjects, obj) } } return (lightobjects)